import HTTP from "@/utils/http";

let Base = "/dictionary/"

// 字典树
export const treeList = (params) => HTTP.get("/dictionary/treeList", { params });
// 字典列表
export const dictionaryList = (params) =>
  HTTP.get("/dictionary/dictionaryList", { params });
// 删除字典
export const RemoveDictionary = (data) =>
  HTTP.post("/dictionary/RemoveDictionary", data);
// 新增字典
export const addDictionary = (data) =>
  HTTP.post("/dictionary/addDictionary", data);
// 更新字典
export const updateDictionary = (data) =>
  HTTP.post("/dictionary/updateDictionary", data);
// 新增字典内容
export const addDictionaryValue = (data) =>
  HTTP.post("/dictionary/addDictionaryValue", data);
// 删除字典内容
export const RemoveDictionaryValue = (data) =>
  HTTP.post("/dictionary/RemoveDictionaryValue", data);
// 更新字典内容
export const updateDictionaryValue = (data) =>
  HTTP.post("/dictionary/updateDictionaryValue", data);
// 字典内容列表
export const dictionaryValueList = (params) =>
  HTTP.get("/dictionary/dictionaryValueList", { params });

export const EmptyDictionaryValue = (data) =>
  HTTP.post("/dictionary/EmptyDictionaryValue", data);

export default {
  treeList,
  dictionaryList,
  dictionaryValueList,
  RemoveDictionaryValue,
  RemoveDictionary,
  addDictionary,
  updateDictionary,
  updateDictionaryValue,
  addDictionaryValue,
  EmptyDictionaryValue
};